<me:UIAB50  x:Class="WPFExcelReport.TAB50XS"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
     xmlns:ucd="clr-namespace:ReflectionStudio.Controls;assembly=ReflectionStudio.Controls"
     xmlns:Localization="clr-namespace:Localization;assembly=Localization"
     xmlns:me="clr-namespace:WPFExcelReport"
     xmlns:T="clr-namespace:WPFExcelReport;assembly=IntexBL"  
     xmlns:PR="clr-namespace:WPFExcelReport;assembly=TICC_PRULES"  
     xmlns:G8="clr-namespace:WPFExcelReport;assembly=TGASTGA" 
     xmlns:AP="clr-namespace:WPFExcelReport;assembly=TAPKOPF" 
      xmlns:GS="clr-namespace:WPFExcelReport;assembly=TGSDAT" 
       xmlns:GD="clr-namespace:WPFExcelReport;assembly=TGAAUF"  
      xmlns:GSC="clr-namespace:WPFExcelReport;assembly=TGSCOLOR" 
     xmlns:AR="clr-namespace:WPFExcelReport;assembly=TABPR"
      xmlns:MU="clr-namespace:WPFExcelReport;assembly=TABAUFM"  
     Loaded="Window_Loaded"
     x:Name="TV" 
 >
    <me:UIAB50.Resources>
        <CollectionViewSource  x:Key="vwMaster"/>       <CollectionViewSource  x:Key="vwDetail"/>
        <ucd:NOTConverter x:Key="not"/>
        <ucd:BoolToVisibilityConverter  x:Key="bv"/>
        <ucd:Divideby10  x:Key="d10"/>
        <ucd:Divideby100  x:Key="d100"/>
        <ucd:Divideby1000  x:Key="d1000"/>
        <ucd:GB2312Convert8859P1  x:Key="gb2312"/>
        <ucd:TextTrimmingConverter  x:Key="Trim"/>
    </me:UIAB50.Resources>
    <Grid IsEnabled="{Binding IsBusy,ElementName=TV,Converter={StaticResource not}}">
        <Grid.RowDefinitions>
            <RowDefinition   Height="Auto" />
            <RowDefinition   Height="1*" />
            <RowDefinition   Height="Auto" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto"/>
            <ColumnDefinition Width="1*"/>
        </Grid.ColumnDefinitions>
        <WrapPanel Grid.Row="0" Grid.Column="0" IsEnabled="{Binding ERLKZ,ElementName=TV,Converter={StaticResource not}}">
            <Button Grid.Column="1" Height="20"  Width="24" Margin="0,0,0,0"  Click="btnPrePlan_Click">
                <Button.Background>
                    <ImageBrush ImageSource="/ImagePackage;component/Images/Refresh.png" />

                </Button.Background>
            </Button>
        </WrapPanel>
        <PR:TSPRULES Grid.Row="0" Grid.Column="1"
                     Name="cRule"  ARTSTAGE="X"        
                     IsEdit="{Binding IsEdit,ElementName=TV}" 
                      WH="{Binding WH,ElementName=TV}" 
                     dwRule="{Binding dwRule,ElementName=TV}" 
                     ORDERNUM="{Binding RULEKEY,ElementName=TV}"
                     P01="{Binding P01,ElementName=TV}"
                         />
        <Grid  Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2"  >
            <Grid.RowDefinitions>
                <RowDefinition   Height="Auto" />
                <RowDefinition   Height="1*" />
                <RowDefinition   Height="Auto" />
            </Grid.RowDefinitions>
            <MU:TABMU     Grid.Row="0"   
                        EXAUF="{Binding AUF,ElementName=TV}"
                     />
            <G8:TABGS08  Grid.Row="1" 
                         Name="cGS08"
                         Visibility="{Binding IsBOM,ElementName=TV,Converter={StaticResource bv}}"
                         EXAUF="{Binding PRART,ElementName=TV}"/>
            <GD:TGD713  Grid.Row="2" 
                    Visibility="{Binding IsAB,ElementName=TV,Converter={StaticResource bv}}"
                    FTAUTOGA="False"
                    AUFTYP="V"
                     ARTSTAGE="X"
                    IsAB="{Binding IsAB,ElementName=TV}" 
                    IsGridShow="False"
                    POSTYP="{Binding POSTYP,ElementName=TV}" 
                    ORDERNUM="{Binding KEY,ElementName=TV}"
                />
        </Grid>
     
    </Grid>
</me:UIAB50>
